<?php
/*
  Template Name: economy
 */
?>

<?php
get_header();
?>
<!-- header -->
        
        <div class="container clearfix">
        
        	<div class="rightCol">
                
				<div id="standardPhotosgallery" class="sliderkit photosgallery-std">
					<div class="sliderkit-nav">
						<div class="sliderkit-btn sliderkit-nav-btn sliderkit-nav-prev"><a rel="nofollow" href="#" title="Previous line"><span>Previous line</span></a></div>
						<div class="sliderkit-btn sliderkit-nav-btn sliderkit-nav-next"><a rel="nofollow" href="#" title="Next line"><span>Next line</span></a></div>
						
						<div class="sliderkit-nav-clip">
							<ul>
                            <?php
                        
						$cultureId = get_cat_ID('news');
						
						$counter = 1;
						$tempContainer = array();
						$args = array('category__and' => array ($cultureId,$cur_cat_id), 'numberposts' => 8);
						$innerPosts = get_posts($args);
						foreach ($innerPosts as $innerPost) {
						$colorClassName = 'cpolitices';
						$finalPath = get_the_post_thumbnail($innerPost->ID);
						 $tempContainer[] = array('colorClassName' => $colorClassName, 'imagePath' => $finalPath, 'postTitle' => $innerPost->post_title, 'catName' => 'الثقافة', 'postLink' => get_permalink($innerPost->ID));
						//print_r($tempContainer);
                            ?>
								<li>
                                	<a href="#" rel="nofollow" title="[link title]"><?php echo $finalPath; ?></a>
                                	<span class="politicOverText">
                                    	<span> <?php echo $innerPost->post_title; ?></span>
                                        <span class="POVcontent"><?php echo substr( strip_shortcodes($innerPost->post_content),0,150); ?> </span>  
                                    </span><!-- politicOverText -->
                                </li>
                          <?php $counter++;} ?>
								
							</ul>
						</div><!-- slider-nav-clip -->
					</div><!-- sliderkit-nav -->
                    
					<div class="sliderkit-panels">
                    <?php foreach ($tempContainer as $curInfo) { ?>
						<div class="sliderkit-panel">
                        	<a href="#" class="quickRead"> قراءة سريعه </a>
							<a href="<?php echo $curInfo['postLink'] ?>"><?php echo $curInfo['imagePath'] ?></a>
                            <h2><a href="<?php echo $curInfo['postLink'] ?>"><?php echo $curInfo['postTitle'] ?></a></h2>
						</div><!-- sliderkit-panel -->
                    <?php } ?>
						
					</div><!-- sliderkit-panels -->
				</div><!-- standardPhotosgallery -->
            
            	<div class="homeadvsLeaderBoard"><img src="images/leaderBoard.jpg" alt="" /></div>
                
                <div class="sectionsArea">
                	<!--<div class="sectionsAreaTags clearfix">
                    	<h2> مواضيع ساخنه </h2>
                        <ul>
                        	<li class="active">
                            	<a href="#">سياسة</a>
                                <div class="up-triangle"></div>
                            </li>
                            <li>
                            	<a href="#">الأنتخابات</a>
                                <div class="up-triangle"></div>
                            </li>
                            <li>
                            	<a href="#">السيسى</a>
                                <div class="up-triangle"></div>
                            </li>
                            <li>
                            	<a href="#">المحاكمات</a>
                                <div class="up-triangle"></div>
                            </li>
                            <li>
                            	<a href="#">مصر</a>
                                <div class="up-triangle"></div>
                            </li>
                            <li>
                            	<a href="#">مبارك</a>
                                <div class="up-triangle"></div>
                            </li>
                            <li>
                            	<a href="#">التحرير</a>
                                <div class="up-triangle"></div>
                            </li>                                                   
                        </ul>
                    </div>--><!-- sectionsAreaCategories -->
                    
                    <div class="sectionNewsArea clearfix" id="section-content">
				<?php 
					echo  loadSection(true , $cur_cat_id);	
				?> 
            </div><!-- sectionNewsArea -->               
                    <a href="#" class="seeMoreFromSection load-chosen" id="load-more" sec="<?php echo $cur_cat_id;?>"> شاهد المزيد </a>
                </div> <!-- sectionsArea -->
                
                 <div class="newsFromSocial clearfix">
					<?php display_tweets(); ?>
                </div><!-- newsFromSocial -->
                
                   
                <div class="sectionsAreaCategories clearfix">
                <h2>البومات الصور</h2>
                <ul>
                    <?php
                    $albumCatId = get_cat_ID('album');
                    $albums = get_posts(array('category__and' => array ( $albumCatId, $cur_cat_id)));
                    $counter = 1;
                    foreach ($albums as $key => $post) {
                        $colorCategory = getColorClassName($post);
                        $colorClass = 'c' . $colorCategory->slug;
                        if ($key === 0) {
//                            $activeClass = ' active';
                            $firstId = "id='first-album'";
                        } else {
//                            $activeClass = '';
                            $firstId = '';
                        }
                        ?>
                        <li class="<?php echo $colorClass; ?> album-act">
                            <a href="#" class="fetch-album" pid="<?php echo $post->ID; ?>" <?php echo $firstId ?>><?php echo $post->post_title; ?></a>
                            <div class="up-triangle"></div>
                        </li>
                        <?php
//                        $counter++;
                    }
                    ?>                                                   
                </ul>
            </div><!-- homePhotoGalleries -->
            <div class="photoAlbums" id="album-container" style="display: none;">

            </div>
                <!-- homePhotoGalleries -->
                
            </div><!-- rightCol -->
            
            <div class="sideBar">
            	
               <div class="importantNewsArea"> 
                    <h2 class="blogersTitle">أسعار العملات</h2>

                    <div class="blogersPosts" >
                        <div class="scroll-pane">
                       <div class="leagueTabel">
                        	<table width="100" border="1" > 
                              <tr>
                                <th class="TeamMT">الفريق</th>
                                <th>لعب</th>
                                <th>فوز</th>
                                <th>تعادل</th>
                                <th>خسارة</th>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo.png" alt="" />
                                    <span> الاهلي </span>
                                </td>
                                <td class="odd">9</td>
                                <td>9</td>
                                <td class="odd">0</td>
                                <td>0</td>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo2.png" alt="" />
                                    <span> الزمالك </span>
                                </td>
                                <td class="odd">9</td>
                                <td>0</td>
                                <td class="odd">0</td>
                                <td>9</td>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo.png" alt="" />
                                    <span> الاهلي </span>
                                </td>
                                <td class="odd">9</td>
                                <td>9</td>
                                <td class="odd">0</td>
                                <td>0</td>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo2.png" alt="" />
                                    <span> الزمالك </span>
                                </td>
                                <td class="odd">9</td>
                                <td>0</td>
                                <td class="odd">0</td>
                                <td>9</td>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo.png" alt="" />
                                    <span> الاهلي </span>
                                </td>
                                <td class="odd">9</td>
                                <td>9</td>
                                <td class="odd">0</td>
                                <td>0</td>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo2.png" alt="" />
                                    <span> الزمالك </span>
                                </td>
                                <td class="odd">9</td>
                                <td>0</td>
                                <td class="odd">0</td>
                                <td>9</td>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo.png" alt="" />
                                    <span> الاهلي </span>
                                </td>
                                <td class="odd">9</td>
                                <td>9</td>
                                <td class="odd">0</td>
                                <td>0</td>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo2.png" alt="" />
                                    <span> الزمالك </span>
                                </td>
                                <td class="odd">9</td>
                                <td>0</td>
                                <td class="odd">0</td>
                                <td>9</td>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo.png" alt="" />
                                    <span> الاهلي </span>
                                </td>
                                <td class="odd">9</td>
                                <td>9</td>
                                <td class="odd">0</td>
                                <td>0</td>
                              </tr>
                              <tr>
                                <td class="TeamMT">
                                	<img src="images/championLogo2.png" alt="" />
                                    <span> الزمالك </span>
                                </td>
                                <td class="odd">9</td>
                                <td>0</td>
                                <td class="odd">0</td>
                                <td>9</td>
                              </tr>
                            </table>
                            </div>

                        </div><!-- scroll-pane -->
                    </div><!-- matchesTime -->
                    
                </div><!-- imprtantNewsArea -->
                
                     
                <?php get_sidebar(); ?>
    </div><!-- sideBar -->

</div><!-- container -->
<?php get_footer(); ?>
<script type="text/javascript">!function(d, s, id) {
        var js, fjs = d.getElementsByTagName(s)[0];
        if (!d.getElementById(id)) {
            js = d.createElement(s);
            js.id = id;
            js.src = "//platform.twitter.com/widgets.js";
            fjs.parentNode.insertBefore(js, fjs);
        }
    }(document, "script", "twitter-wjs");</script>